Hi Cristian,
I don't think you can directly pass the strings as mentioned above in CAN protocol. CAN is a well-defined protocol, which has a very specific way to pass in any information.
Please refer to the following documentation, to learn more about transmitting a message in CAN protocol: https://www.mathworks.com/help/vnt/ug/can.channel.transmit.html
Also the CAN (Controller Area Network) protocol and the VISA (Virtual Instrument Software Architecture) protocol serve different purposes and operate at different levels within the communication stack, making the idea of "querying" in each context quite different.
In CAN, you don't typically "query" a device in the same way you might with a command/response protocol. Instead, you send and receive messages with identifiers that indicate their priority and type.
Where as with Visa, you can send SCPI (Standard Commands for Programmable Instruments) commands or other protocol-specific queries to instruments and receive responses. This is more in line with the traditional sense of "querying" a device.
For more examples on the CAN communication, refer to the following link:
https://www.mathworks.com/help/vnt/examples.html?category=can-matlab-communication&s_tid=CRUX_topnav
I hope it helps!