简体   繁体   中英

How to query table when table name has hyphen in Redshift Spectrum?

I am attempting to query a table that has a hyphen in it.

I have tried backticks and quotes (`, ', ") and they don't work.

Query

select * from hubspot.contacts__form-submissions

Error message:

Error running query: syntax error at or near "-" LINE 7: from hubspot.contacts__form-submissions ^

I don't have write permissions so I can't rename the table.

Any suggestions on how I can query this?

Try

select * from hubspot."contacts__form-submissions";

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM