PxPlus User Forum

Twitter Twitter Twitter

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Jeffrey Ferreira

Pages: [1] 2 3 ... 13
1
Web Services / Re: Posting a File to a Web Service
« on: May 24, 2024, 04:41:42 PM »
i think the problem is this line
Content-Disposition: form-data; name="xmlsing"; filename="xmlsing.xml"

Mine looks like this
Content-Disposition: form-data; name="filename"; filename="s:\jeff\Cleary_Quote.xml"

i feel like your line should like something like this:

Content-Disposition: form-data; name="filename"; filename="xmlsing.xml"
in other words
the value that name =  points to should be the key in the next key value pair
i have to head out but i'll try to check back in again later on this.
                                                           

2
Web Services / Re: Posting a File to a Web Service
« on: May 24, 2024, 04:10:23 PM »
Henderson, for me the problem was that keyword file/filename that i had to pass in.
i feel like you might have to pass in the word "xml"
i could be wrong.
do me a favor - you know where i have
1080 let BODY$=UPLOAD'BODY$() ! Calling Stephane's code
after you execute this method
print the mid(body$,1,300) and then send the contents to this thread...

3
Web Services / Re: Posting a File to a Web Service
« on: May 24, 2024, 02:55:03 PM »
Hi Henderson,

here was is my best try to scale down with no extra stuff
you need Stephane's program http.upload.pvc for this to work. The other stuff is standard pxplus.
if you can't get it working let me know.

0010 begin
0020 precision 4
0030 let XML_FILE$="s:\jeff\Cleary_Quote.xml" ! Your File would be different
0040 let RAW_CREDENTIALS$="login:password" ! Using Basic Credentials then separate your login and password with a colon before calling base64 program
0050 call "*web/base64;ENCODE_STR",RAW_CREDENTIALS$,BASE64_CREDENTIALS$
0060 let EXTRA_HEADERS$="Authorization: Basic "+BASE64_CREDENTIALS$
0070 let URI$="https://staging.saberis.com:9000/api/v1/documents/modules/21/upload"
0080 gosub HELPER
0090 call "*plus/web/request",URI$,BODY$,RESPONSE$,RESPONSE_HEADER$,CONTENT_TYPE$,"",EXTRA_HEADERS$
0100 print RESPONSE_HEADER$
0110 print RESPONSE$
0120 msgbox "Done"
0130 end
1000 ! ^1000
1010 HELPER:
1020 let FIELD_NAME$="filename" ! This part was custom for my api / yours will probably be different
1040 call "*tools/readfile",(XML_FILE$),FILE_CONTENTS$
1050 let FILE_MIME_TYPE$="multipart/form-data"
1060 let UPLOAD=new("http.upload",FIELD_NAME$,XML_FILE$,FILE_CONTENTS$,FILE_MIME_TYPE$) ! This is Stephane's program http.upload.pvc that handles the boundaries (this is part i was messing up (the boundaries))
1070 let CONTENT_TYPE$=UPLOAD'CONTENT_TYPE$
1080 let BODY$=UPLOAD'BODY$()
1090 return

4
Hi,

i got it to work  :) with Stephane's helper class.
thank you so much.
at least the response said message queued and i'm pretty sure that means it worked.
i have to read thru Stephane's class now and figure out what on earth he did.

jeff

5
Web Services / Re: Posting a File to a Web Service
« on: May 18, 2024, 12:33:29 PM »
Here is my curl command that worked

curl -k  -H "Content-Type: multipart/form-data" -H "Authorization: Basic  Base64Credentials" -F file[filename]=@s:\jeff\Cleary_Quote.xml -X POST https://staging.saberis.com:9000/api/v1/documents/modules/21/upload

i'm going to try adding in what Stephane said and see if that helps.

6
Web Services / Re: Posting a File to a Web Service
« on: May 18, 2024, 12:17:34 PM »
Hi Mike, i tried your method...
of course i know i'm doing something wrong.
but i think it might have something to do with what Stephane said
the api says i have to  reference a field name and a filename

Here is there sample post below.....maybe i have to try sending this filename somewhere..
i'm going to try and find my curl command that worked and attach.

POST /api/v1/documents/modules/17/upload HTTP/1.1
Host: {host}
Authorization: Basic [BASIC_ENCODED_LOGIN_INFORMATION]=
Cache-Control: no-cache
Content-Type:https://forum1.pvxplus.com/Themes/vVide/images/bbc/bold.gif multipart/form-data; boundary=----
WebKitFormBoundary7MA4YWxkTrZu0gW
------WebKitFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name="filename"; filename="Paradigm.xml"
Content-Type: text/xml
------WebKitFormBoundary7MA4YWxkTrZu0gW--



7
Web Services / Posting a File to a Web Service
« on: May 17, 2024, 09:47:02 PM »
Hi List,
in the past i could never get *plus/web/request work with uploading a file.
i can get it to work in postman, curl and powershell....but i cannot get syntax right in pxplus
i'm referring to line 100 .
does anyone know what i'm doing wrong or has used *plus/web/request to post/upload file
i dont want to use a 3rd party utility if i can help it

0040 let RAW_CREDENTIALS$="username:password"
0050 call "*web/base64;ENCODE_STR",RAW_CREDENTIALS$,BASE64_CREDENTIALS$
0060 let EXTRA_HEADERS$="Authorization: Basic "+BASE64_CREDENTIALS$
0070 let MIME_TYPE$="multipart/form-data"
0080 let URI$="https://staging.saberis.com:9000/api/v1/documents/modules/21/upload"
0100 let BODY$="filename=Cleary_Quote.xml"
0110 call "*plus/web/request",URI$,BODY$,RESPONSE$,RESPONSE_HEADER$,MIME_TYPE$,"",EXTRA_HEADERS$


thanks

jeff

8
ODBC / Re: ODBC Service Crashing
« on: April 26, 2024, 09:49:28 AM »
Hi Deven,

The Power BI Reports are specific to this one company so no it is only happening at this company. But i have more companies asking to query data using power bi

jeff



9
ODBC / Re: ODBC Service Crashing
« on: April 26, 2024, 09:18:00 AM »
I upgraded to version 7.10 and the service still crashes with this generic error.  The problem is I keep having more and more customers wanting to use Power BI to connect to our data.

10
ODBC / ODBC Service Crashing
« on: April 12, 2024, 08:09:26 AM »
Hello All,

I  have a customer who uses ODBC a lot to access their pxplus files. We have service crashes quite often.
I'm assuming the first thing we should do is update their ODBC Version but before we do that, is their anything that could possibly be going on

thanks

jeff

Error Message:
Faulting application name: pxpiosvr.exe, version: 5.20.0.0, time stamp: 0x51815515
Faulting module name: ntdll.dll, version: 10.0.14393.6343, time stamp: 0x6502749b
Exception code: 0xc0000005
Fault offset: 0x000587a9
Faulting process id: 0x8d2c
Faulting application start time: 0x01da8ccff7520e30
Faulting application path: C:\PVX Plus Technologies\File Server\pxpiosvr.exe
Faulting module path: C:\Windows\SYSTEM32\ntdll.dll
Report Id: e605ac47-8a76-4ee5-abcb-93544bd6bc91
Faulting package full name:
Faulting package-relative application ID:

11
Programming / Re: winprt
« on: March 21, 2024, 03:29:15 PM »
Hi Sam,

We've had a similar problem before.
winprt works fine (using windows print driver)
windev does not work
even though i'm pretty certain windev does not use the windows print driver, we had to change our windows print driver to an HP Universal Driver in order to print pcl or any of those mnemonics you see inside the *dev\hplaser. I dont know why that is but i would give it a try.

Jeff

12
ODBC / Re: slowing down an ODBC query
« on: February 20, 2024, 04:22:11 PM »
Thank you Devon. i will ask the customer if they would be partial to the Dirty Read.

13
ODBC / slowing down an ODBC query
« on: February 20, 2024, 11:31:43 AM »
Hi All,

we are having an issue whereby when a user does a power bi query against our pxplus data via odbc it really can slow down performance for everyone else. Does anyone know of a way i can slow down/throttle pxpiosrv. Or maybe some other solution.

Jeff

14
Programming / Re: Flash a Message
« on: January 27, 2024, 09:37:41 AM »
Thank you for all the ideas. I will implement one of them.  I just wanted to make sure I wasnt missing something like a call back feature like in javascript.  I saw background loading of controls and that made me think that perhaps something like a call back could be present. I appreciate every ones ideas. thank you.

15
Programming / Flash a Message
« on: January 25, 2024, 02:15:21 PM »
Hi All

is there a way to flash a message on the screen in a multiline and then clear it after a few seconds.
i was going to implement with the timeout but i thought i would ask if there was a more sophisticated way to do this.
i'm trying to avoid adding message boxes.

thanks

jeff

Pages: [1] 2 3 ... 13