ePrivacy and GPDR Cookie Consent management by TermsFeed Privacy Policy and Consent Generator

MS4BI® - Mandragore System 4gl Business Insights -

Business Intelligence Reinvented: Simple, Effective, Powerful, and Affordable.

  • Create Windows and Web applications with real-time data updates for always relevant and up-to-date information.
  • Boost your productivity with MS4Script: low code, maximum results, minimum effort.
  • Lightweight, intuitive, and fully responsive for an optimal user experience, from analysis to interaction.

Make your data speak and make decisions that matter. Turn your information into concrete and impactful results.

Try it now!
MS4BI_Team

MS4BI : QUERY

      

MS4_QUERY :WEB{driver}

Syntax

QUERIES ALL DATABASES.

Definition

Creates a WEB query to interrogate ADO,ODBC, DSN or MS4 DB databases
and publish on the web your excel file for example in 2 minutes
  	  	
  Ms4_Query: web{driver} 
   (optional)Option : BEGIN   Attributes  END
      (  "string or literal = SQL " + "rest of string or literal = SQL instruction",
(optional : variables) ,ivalue, Lvalue, fvalue, dvalue, ) ;
- The variables are defined using the following convention: %i integer, %l long ,%f float ,%d double ,%s char or text

Example 1 ADO EXCEL

  		   
DBconnect{Ado:"xls"}("#DRIVERSYS+:\MandragorePlanete\MS4BI\02-DEMO....\2-QUERIES\EXCEL\..\viewInvoices.xls");
Ms4_Query: web{Ado:"xls"}("SELECT * FROM [viewInvoices$]   " );

OR

 Ms4_Query:  web{Ado:"xls"} 
Option  : 
  BEGIN 
   Style   :$BLue ,
   height  :550,     
   pagesize:100,
   EXPORTEXCEL : yes   , 
   Pageable :yes,
   Resizable :yes, 
   Sortable :yes,
   ViewResult:yes,
   filterable:yes
  END  
 ("SELECT *  FROM [Sheet1$]   " );	

or

 FormPlus : Ms4_Query  {Ado:"xls"} 
	BEGIN
      SetUniCode(True);
         DBconnect{Ado:"xls"}(LcurrentDirExcel);
        Ms4_Query: Web{Ado:"xls"}
         Option  : 
         BEGIN 
              Style :$METRO  
          END 
          ("SELECT * FROM [中国最大の都市のリスト$]     " );
       END ;
	
	

Example 2 MS4 DB

  	
   Setting :
	Chart :
	Backgroundcolor : $color_bkms4bi 
	ToolBarExport  : yes  ;
     
      DBconnect{Ms4DB}(LEnvDemoExcelDB); 
       Ms4_query:web{ms4db}   
        ( " SELECT OrderID ,CustomerID,	EmployeeID,	" + 
           "        OrderDate,	RequiredDate,	ShippedDate "+
           " from   [ms4EmplConsolidationBusiness]  order by EmployeeID desc limit 2 " ) ; 
                   ** TOP 2 employeeid
	

Example 3 SQLITE3 or MS4 DB

  	
DBconnect{sqlite3}( LEnvSQLDB);

 
 Ms4_Query: Web{sqlite3}
 ("SELECT * FROM     sqlite_master   ORDER BY type  ");

	

Example 4 Dynamic instruction

  
BEGIN 
  TEXT  Stable1 := "ms4EmplTotalBusiness2013"; 
  integer IretSql;
   DBconnect{Ms4DB}(LEnvDemoExcelDB);   
   Ms4_Query: Web{ms4db}
   Option  : /* optional */
		BEGIN 
            style :$BLACK ,
		
 		END  
("SELECT  A.lastname as myname, printf('%.02f',b.BUSINESSID2011) as YEAR2011,printf('%.02f',A.BUSINESSID2013 ) AS YEAR2013  "+
" FROM   %s  as A  join  ms4EmplTotalBusiness2011  as B "+
" where  a.lastname = b.lastname", Stable1 ) return IretSql;/* dynamic sql : possible : %s = Stable1 */
  END ;	

Query + dynamic Sql

MS4BI® SELECT A.lastname as myname,
printf('%.02f' .........


Toolbar : Export

Remarks

- The SQL instruction must respect syntax depending on the type of connector
- Max. number of characters 2500 per SQL instruction
- The variables are defined using the following convention: %i integer, %l long ,%f float ,%d double ,%s char or text -Option :
BEGIN
style : $MOONLIGHT or $BLACK or $WHITE or $BLUE or $METRO or $SILVER ,
height : xxx (numeric) ,
EXPORTEXCEL : yes or no ,
pagesize : xx (numeric),
popEdit : yes or no ,
ColumMenu : yes or no ,
Pageable : yes or no ,
Resizable : yes or no ,
Sortable : yes or no ,
ExpandFirst : yes or no ,
filterable : yes or no
END
NB :
yes=1
no =0

ALL EXAMPLES

QUERIES standard styles Ms4bi.



BLACK



Toolbar : Export

BLUE OPAL


METRO


UNIFORM


GREEN


BOOTSTRAP


CUSTOMIZE




Mandragore Planete
15 rue des Halles
75001 PARIS FR
T: (+33) 1 76 46 09 83
New branches opening soon in Bordeaux FRANCE,
Montreal CANADA,
San Franscisco USA
Mediator
CMAP 39 av. Franklin D. Roosevelt
75008 PARIS FR
T: (+33) 1 44 95 11 47
consommation@cmap.fr