Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

CEP Panel Dev - connecting to MS SQL

Explorer ,
Dec 07, 2020 Dec 07, 2020

Hi all;

 

My CEP panel needs to poll a MS SQL Table to look for an ‘order’ for a video to be created and rendered.

I have no problem connecting to MS SQL in a standalone Javascript under Node, but can’t figure out how to do this in the main.js of my CEP Panel.

 

Thanks for your help!

TOPICS
Expressions , Scripting , SDK , User interface or workspaces
947
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 3 Correct answers

Community Expert , Dec 09, 2020 Dec 09, 2020

i gather the ms sql table is on a remote server, right?

if i remember correctly, you have to have some accesss point set up on that server, like an asp page that would accept a REST call and return a result of the query.

in that case, isn't it a simple manned of sending a REST call from the main.js file in javascript?

Translate
Explorer , Dec 09, 2020 Dec 09, 2020

Thank you for your repsonse Shachar;

Interesting concept. 

I have since found an article on building a Node JS in a panel; perhaps that will provide me with direct access. If not, that REST workaround may be the trick.

Again, thanks.

 

 

Translate
Explorer , Dec 29, 2020 Dec 29, 2020

Hi Sachar;

just an update; I tried for a week to get SQL access from the Javascript in the CEP - no luck.

So, I am instead going ahead with your suggestion: I've created and API and am calling that from the .JS in the CEP. Thank's for the tip.

 

 

Translate
Community Expert ,
Dec 07, 2020 Dec 07, 2020

I think you are on the wrong forum. Sounds like a Dreamweaver or Cold Fusion question.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 07, 2020 Dec 07, 2020

Thanks Rick; this relates to developing Extensions (CEP panels) inside After Effects using Javascript and Extendscript. It's not a web-page thing .. other than Adobe chose to use HTML/CSS for the presntation of the panels. 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 07, 2020 Dec 07, 2020

Good to know. I'm just getting started with scripting for AE. Did a bunch a very long time ago. I've got more than 200 custom presets that I am integrating into scripts/plug-ins. It's been quite a journey. It's something to keep me busy while most of my production work is shut down. 600 people can work shoulder to shoulder to build a new condo and shopping center a mile from my house but I can't get a crew of 10 together to shoot some video. 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Dec 09, 2020 Dec 09, 2020

i gather the ms sql table is on a remote server, right?

if i remember correctly, you have to have some accesss point set up on that server, like an asp page that would accept a REST call and return a result of the query.

in that case, isn't it a simple manned of sending a REST call from the main.js file in javascript?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 09, 2020 Dec 09, 2020

Thank you for your repsonse Shachar;

Interesting concept. 

I have since found an article on building a Node JS in a panel; perhaps that will provide me with direct access. If not, that REST workaround may be the trick.

Again, thanks.

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 09, 2020 Dec 09, 2020

I meant to write " ....building a Node JS SERVER in a panel;"

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 29, 2020 Dec 29, 2020
LATEST

Hi Sachar;

just an update; I tried for a week to get SQL access from the Javascript in the CEP - no luck.

So, I am instead going ahead with your suggestion: I've created and API and am calling that from the .JS in the CEP. Thank's for the tip.

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 11, 2020 Dec 11, 2020

Hi, I'm quite new to extensions and haven't done any using node yet but I remember reading that you need to enable it in your manifest. 

<Parameter>--enable-nodejs</Parameter>

 And you need to be on CEP 6.1 or higher.

This link has more infor https://github.com/Adobe-CEP/CEP-Resources/blob/master/CEP_8.x/Documentation/CEP%208.0%20HTML%20Exte... search "--enable-nodejs"

Hope this is what you are looking for.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Dec 11, 2020 Dec 11, 2020

Thanks for taking the time to respond Greg5f9B ;

 

Here's the link to the article I mentioned earlier and am using to get this running: https://medium.com/adobetech/how-to-build-a-node-js-server-in-a-panel-ba1d63ea67e2;   It has a link to the same Github page as you're suggesting!  

 

I hope to get the time and get this part working soon. I'm nearing completion of this massive 1-man undertaking. 5 Modules working independently but connected via a database, The modules are working fine but the integration via DB is taking time. I quit programming and development many years ago ...  some things have changed 😉 but I'm having a real blast. 

 

 

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines