Home > Software engineering >  From the ACCESS database to the SQL SERVER, the SHAPE changes can statement
From the ACCESS database to the SQL SERVER, the SHAPE changes can statement

Time:10-05

Code is as follows, can you tell me the to the SQL SERVER database, how to rewrite the code, thank you,

 
SQL="SHAPE {SELECT c. user number, c. username, c., c. floor, c. unit number, c. room number, c. table number, c. phenotypic name, c. billing type, c. billing category, c. monovalent, c. purchase number," _
& "Purchases of c. c. purchase amount, c. operation date, c. operator, c. operations, c. total number of operations, c. operation type, c. paper number, c. effectiveness, d. the last balance, d. cash balances, paid-in amount" _
& "FROM" _
& "(" _
& "(" _
& "SELECT user number, b. b. user name, b., b. floor, b. unit number, b., room number, b. table number, b. phenotypic name," _
& "B. billing type, b. billing category, b. monovalent, b. buy number, b. purchases, b. purchase amount, b. operation date, b. operator," _
& "B. b. operating frequency, total number of operations, b. operation type, b. paper number, b. effectiveness, b. fixed number" _
& "FROM" _
& "(SELECT * FROM yhxx WHERE user id=" & amp; LBianhao & amp; ") AS a "_
& "LEFT the JOIN" _
& "(SELECT * FROM SDJL WHERE user id=" & amp; LBianhao & amp; "AND the bill number=" & amp; PJDH & amp; "AND the operation type='buy'" _
& "AND effectiveness='effective' ORDER BY table number" _
& User id=") AS b ON a. b. user id "_
& ") AS c "_
& "LEFT the JOIN" _
& "(SELECT * FROM yueb WHERE user id=" & amp; LBianhao & amp; "AND the bill number=" & amp; PJDH & amp; ") AS d "_
& "ON c. user id=d. user number AND c. paper number=d. paper number" _
& ") the order by c. user number, c. table number, c. operation date "_
& AS "} AS Command1 COMPUTE Command1 Command2 BY 'user id', 'user name', 'community', 'building date', 'unit number', 'room number', 'bill number', 'the last balance', 'cash balances',' paid-in amount ', 'operator' and 'operation type "


CodePudding user response:

SQL server also has a shape statement

Specific look here
http://support.microsoft.com/kb/189657

CodePudding user response:

reference 1st floor clear_zero response:
SQL server also has a shape statement

Specific look here
http://support.microsoft.com/kb/189657


Thank you very much
  • Related