Amicuk Programming Answers

Problem In The Query

2015-10-11   Views:0


Hai All,            I have created a login form in screen painter (which contains two textbox and a login button). When login button is clicked, I want to check whether the username and password matches in the table (@EMPA). I have a problem while ch

Hai All,
           I have created a login form in screen painter (which contains two textbox and a login button). When login button is clicked, I want to check whether the username and password matches in the table (@EMPA).
I have a problem while checking with the query
This is User Defined Function a have used
Private Sub UDFCheckInTableLog()
            Dim rs As SAPbobsCOM.Recordset = ocompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
            rs.DoQuery("SELECT T0.U_user FROM [dbo].[@EMPA]  T0 WHERE T0.U_user ='" & euser & "' AND TO.U_pass ='" & epass & "'")
            rscount = rs.RecordCount
            If rscount > 0 Then
                '//There is a record that Matches
                REC = True
                '//To clear the values in the text box
                '//This means NO Record Matches
                REC = False
            End If
        Catch ex As Exception
            SBO_Application.MessageBox("UDFCheckInTableLog :" & ex.Message)
        End Try
    End Sub
I get this error message
1)[microsoft][ODBC SQL Server Driver][SQL Server] Incorrect syntax near the keyword 'TO'.
2))[microsoft][ODBC SQL Server Driver][SQL Server] Statement(s) could not be prepared.

The replay answer
You're trying to use Table Alias(T0), i'm guessing its not allowed. Try also to remove dbo, try @EMPA or just EMPA.

Go to See the other 6 answers

Problem in Adhoc Query's set operation functionality.

Category:DefaultRelease time:2015-10-11Views:130

Hi Experts, I am facing problem executing Adhoc Query's set operation functionality. In Selection Tab, following operations are performed :- Execute a query and mark it as 'Set A'.(Say Hit list = X) Execute another query and mark it as 'Set B'.(Say H[More]

Problems in SQL Query

Category:DefaultRelease time:2015-10-11Views:130

Dear All, I am having some problem in SQL query. I am trying to get total sum of one inventory using the following query it works fine: sum(case when mt.transaction_quantity > 0 then (mt.transaction_quantity) else 0 end) "TOT_IN" ,sum(case wh[More]

Problem with a query with a BLOB data type

Category:DefaultRelease time:2015-10-11Views:130

Hi i've a problem with this query in 11g. R1 SELECT       LOGTIMESTAMP,       LOGTIMEMILLIS,       MSGID,       XMLTYPE(MESSAGEBODY, nls_charset_id('AL32UTF8')).getClobVal()  as LLamada FROM     vordel.AUDIT_MESSAGE_PAYLOAD,     vordel.AUDIT_LOG_POIN[More]

Strange problem in a query

Category:DefaultRelease time:2015-10-11Views:130

Hello all, I'm facing a non-sense problem in a query, I hope you could help me. I have defined a structure in the rows of my query. Inside the structure, I have defined several selections and formulas. Selections are basically account intervals and f[More]

Problem in parameter query.

Category:DefaultRelease time:2015-10-11Views:130

Post Author: eaglesoft CA Forum: Data Connectivity and SQL I'm using Crystal reports xi. I have problem on parameter fields.    field name-EmployeeCode, datatype-String.In report,I kept the following query in selection expert,(EmployeeTable.EmployeeC[More]

Problem in xml query

Category:DefaultRelease time:2015-10-11Views:130

Hi I am working on BLS and having problem in xml query.I want to perform some calculation over xml columns.Than total of this as a new column.I can do this part in logic editor itself but can i do these both task by XSLT. Can be made our own XSLT for[More]

Navigational Attribute Problem in Input Query

Category:DefaultRelease time:2015-10-11Views:130

Hi, I am having a problem in input query implementation which uses a navigational attribute. I have, for eg, only one char 'customer' in rows; i want to exclude the customers with the status D (deleted) from displaying (Status is nav. attr. of custom[More]

Problem in update Query of  MySQL

Category:DefaultRelease time:2015-10-11Views:130

Hi I have a large amounts of records in a teble & i want to update the records in a particular condition but it takes time in updating. I have also used batch update but it's also not going to solve my problem. can anyone help what should i do to fre[More]

Problem With The Query

Category:DefaultRelease time:-0001-11-30Views:130

Hi gurus, I have a problem in a query I have a lot of records that are the same and I don’t want to sum the value of them more than once. How can this be done?? The following table should illustrate my problem: DEPT--MONTHCFBID----SCORE ALST--APR100-[More]

Problem with Hierarchical query

Category:DefaultRelease time:-0001-11-30Views:130

Gurus, I have a problem with hierarchical query, which I am pasting below. select sys_connect_by_path (Fname,'/')"PATH",Fname,id,level ,(SELECT COUNT(ID)-1 FROM (SELECT CONNECT_BY_ROOT LNAME LNAME,ID FROM CMT_PERSON START WITH ID = 'emplo0000000[More]

Problem with af:query

Category:DefaultRelease time:-0001-11-30Views:130

Hi, I have a problem with af:query. Here's what I do: 1. create a VO, define view criteria 2. drag and drop view criteria from data controls to an empty form, choosing query and table 3. When I run the page and click any of the buttons, I get: "Becau[More]

Hi, I have set up the business partner and linked it to the FI customer.  This customer has open items to the value of u20AC2.1 million.  I also set up the collection strategy and set it up to pick up amount to be collected of >u20AC2000. However whe [More]
When I got my Fifth Gen last year, I was thrilled. Started a library of books and music immediately from cds I owned. Unfortunately I was mugged, and it was stolen. My kids bought me a new one (engraved w love), and now I have 55 gigs of books and mu [More]
Hi all i am doing BI to XI integration using how to guide of SAP while activating datasource i am getting two errors 1)Error generating Web service /BIC/CQSENDXML00001000 2)Error when activating DataSource SENDXMLDATATOBI can anybody let me know how [More]
What is the keyboard shortcut for Save a Copy in Acrobat 9.0? The menu says it's "y" but "y" is the shortcut for Modify PDF Portfolio. It's also not Shift+Ctrl+S; that's the shortcut for Save As...Thank you for your post. These forums [More]
Hi and Happy New Year, I have a vector in my java application which contains a number of elements that is not fix which means each time the number of elements might change. I want to retrieve the elements of the vector 3 by 3 its like table records p [More]
how can i re downlaod itunes or get rid of this message so i can re download itunesFirst, stop being impatient.  We are users like yourself and not paid to respond. Second, what is the precise text of the message appearing?  We are not mind readers.R [More]
Hi I wonder if u guys can help, I am interested in learning about modelling in general and I am trying to find information on the advantages and disadvantages of UML as a modelling language compared to other modelling techniques. I have only found sm [More]
I recently bought an HP DeskJet 3510 printer and use Mac OS X 10.6 and 10.8 on various computers.  Since opening the box I've had nothing but problems with wireless printing.  The drivers are completely useless and the set up is ridiculous since you [More]
I am trying to export a movie from Quicktime Pro to my Ipod and it keeps getting stuck at 8%. It has been there for 2 hours now. When I cancel it and try again, it freezes at 8% again. Please help.this happens to me when trying to get a video off the [More]
In Lightroom 5.7 CC, I experience "edit in" problem when I open a file (PSD, TIF or JPEG) to Photoshop CC. The following message is displayed: "Some of the application components are missing from the Application directory, Please reinstall [More]