Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Weird problem
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Title:
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 7
Network:
Windows 2003 Server
Database:
MS SQL Server
Miscellaneous
Thread ID:
01519939
Message ID:
01519965
Views:
32
>>Here is what I see in SQL Profiler:
>>
>>
>>exec sp_executesql N'-- NAOMIN/ADMIN sysmanager:item_edit.sct:my_dataform.dataenvironment.opentables:81
>>
>>if object_id(''tempdb..#csrI_Item'') is not null drop table #csrI_Item
>>select * 
>>  into #csrI_Item
>>  from i_items  
>>  where department =  @P1  --''RETAIL    ''
>>  and category = @P2  --''BK-CHILD  ''
>>  and item = @P3  --''ALICE     ''
>>SELECT * from #csrI_Item',N'@P1 varchar(10),@P2 varchar(10),@P3 varchar(10)','RETAIL    ','BK-CHILD  ','ALICE     '
>>
>>-- and then the next batch which is failing 
>>
>>-- NAOMIN/ADMIN sysmanager:item_edit.sct:my_dataform.dataenvironment.opentables:88
>>
>>select * from i_attlnk WHERE invent_id in (select invent_id FROM #csrI_Item)
>>DROP TABLE #csrI_Item
>>
>>BTW, the fields in the table are CHAR(10), not varchar(10), not sure if this is important.
>>
>>So, the reason for failure is obvious now. Do you see a way to solve without embedding values back?
>
>I don't see the reason :-)
>What is it?

Do you want me to torture you? :)

I give you 5 more minutes for figuring this out. BTW, I should have figured it out myself right away, but only after I run Profiler by your advice it became obvious for me.

Funny thing that I spent more than 1h. on this problem - now, it seems I have to go back as I don't see an alternative.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform