🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: cn.bbs.comp.database
Article #10775

pb5.0���!

#10775
From: ��
Date: Sun, 30 Nov 1997 00:00
40 lines
3539 bytes
��λǰ�����֣�
    ������ʹ��powerbuilderʱ������һ�������⡣
    ��̨Ϊ:WinNT+Sybase11.1(server)
    ǰ̨Ϊ:Win95+Sybase11.1(client)+powerbuilder5.0
    ������server��sybase�ϱ�д��һ�洢��̣�stored procedure����
��Ϊ"joinwith",�Ȱ�ijЩ��ݷŵ�һ��ʱ���У��� select a, b, c  
into  #temp1  from.... ��䣩���ٰ�ijЩ��ݷŵ���һ��ʱ���У���
 select  x, y, z  into  #temp2  from.... ��䣩������������
ʱ�������������� select  b, c, y, z  from  #temp1, #temp2  
where #temp1.a=#temp2.x ��䣩��
     Ȼ����powerbuilder�Ͻ���һ����ݴ���(datawindow)����Ϊ
"d_store"����"data source"��ѡ��"stored procedure"�����Ϊ
'grid'����"OK"��ѡ��洢���"joinwith"�����һ��ݴ��ں�
ʹ��"preview"�鿴,��ݴ�ȡ�ɹ������������ȷ��
     ��������ڣ���ʹ�ñ��˱�д��Ӧ�ó���ʱ������ȡ���ڱ��˵�Ӧ
�ó����У��Ƚ�����sybase�����ӣ������������(transaction)SQLCAΪ��
     SQLCA.DBMS="SYC"
     SQLCA.database="testdb"
     SQLCA.LogID="sa"
     SQLCA.LogPass="***"
     SQLCA.ServerName="wenn"
��server��������ȷ��Ȼ���һ���ڣ�������һ��ݴ���(dw_1)����һ
��ť(cb_1)����ݴ����ڴ��ڴ�ʱ���Ѿ���������������� 
dw_1.settransobject(sqlca)��䣩����ʹ������ݴ��ڶ���"d_store"
���ӣ��� dw_1.dataobject="d_store" ��䣩����ť���ڼ�����ݣ���
"clicked"�¼�(event)Ϊ��dw_1.retrieve()�������б��˵�Ӧ�ó���ʱ��
��������ڣ�������cb_1ʱ����ʾ"datawindow error"��Ϣ��
SELECT INTO command not allowed within multi-statement transaction.
     ���ʹ��"joinwith"����洢��̣�������û��"select into"��
��Ĵ洢��̣��Ϳ����ñ��˵�Ӧ�ó�����ȷȡ��֤����Ӧ�ó���ű���д
��ȷ�������ೢ�԰�"joinwith"��Ϊ���Ȳ���һ��ʱ�?��create table 
#temp1.... ��䣩���ٰ�һЩ��ݲ�����У��� insert into #temp1....
��䣩������ͬ��������Ӧ�ó���ʱ��ʾ"datawindow error"��Ϣ��
CREATE command not allowed within multi-statement transaction.
     �Ƿ��������������Ӧ�������transcation������Ӧ����α�д
�洢���"joinwith"�����߿ɷ��ṩ��ȡ���ѯ�ĵط���
     Thanks a lot��
--
�� ��Դ:����ˮ˼Դվ bbs.sjtu.edu.cn��[FROM: www]
Technical Details
Message-ID: <3Lj5L4$YuK@bbs.sjtu.edu.cn>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: Chinese,GB
X-Google-Thread: 101948,7b5771022c69e32d,start
X-Google-Attributes: gid101948,public
From: weandy.bbs@bbs.sjtu.edu.cn (��)
Subject: pb5.0���!
Date: 1997/11/30
Message-ID: <3Lj5L4$YuK@bbs.sjtu.edu.cn>
X-Deja-AN: 293862589
X-Filename: database/M.880877812.A
Organization: ��ˮ˼Դվ
Newsgroups: cn.bbs.comp.database